package entity

import (
	"passwordBook/config"
	"time"
)

type BConfig = config.BookConfig
type PwBook struct {
	Id         string `gorm:"primary_key"`
	Name       string
	CreateTime time.Time
	UpdateTime time.Time
	Config     BConfig  `gorm:"type:json"`
	Items      []PwItem `gorm:"foreignKey:BookId;reference:Id;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
}
